package com.liyang.microservice.service.service;


import com.liyang.microservice.service.service.api.ConsumerService3;
import com.liyang.microservice.service.service.api.entity.User;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author Administrator
 * @version 1.0
 * @Title: ConsumerServiceImpl
 * @description TODO
 * @date 2021/4/24 0024 21:44
 */

@RestController
public class ConsumerServiceImpl implements ConsumerService3 {
    @Override
    public String service() {
        return "Consumer3 invoke ";
    }

    @Override
    public User pathUser(Long id) {
        User user = new User();
        user.setId(id);
        user.setName("pathUser");
        return user;
    }

    @Override
    public User getUser(String name) {
        User user = new User();
        user.setId(1L);
        user.setName(name);
        return user;
    }

    @Override
    public User postUser(User user ) {
        return user;
    }

}